<?php
namespace API\Controller;
use Think\Controller;
class MasterController extends Controller {
    public function getMasters(){

        // $m_id = $_GET['m_id'];

        $masters = M('masters');
        $data = $masters -> order("m_id")->select();

        echo json_encode($data);
         echo "<br>";

    }
    public function getMastersById(){

        $m_id = $_GET['m_id'];

        $getMastersById = M('masters');
        $data = $getMastersById -> where("m_id='$m_id'")-> select();

        echo json_encode($data);
         echo "<br>";

    }
}
?>
